package singleton;

/**
 * @author wcj
 * @Date 2021/6/19 20:04
 * @Version 1.0
 */
public class HungrySingleton {

 private static HungrySingleton singleton = new HungrySingleton();

 private HungrySingleton() {
 }

 /**
  * 饿汉式的单例模式
  *
  * @return
  */
 public static HungrySingleton getSingleton() {
  return singleton;
 }
}
